import axiosInstance from "../utils/axios.ts";
import type {Page, PageResult, TimeRange} from "../types";
import type {DeviceRecord, VehicleRecord} from "../types/record";


export const getVehicleRecord = (params: Page & TimeRange) => {
    return axiosInstance.get<any, PageResult<VehicleRecord>, Page & TimeRange>("/excel/getcar", {
        params
    })
}

export const getDeviceRecord = (params: Page & TimeRange) => {
    return axiosInstance.get<any, PageResult<DeviceRecord>>("excel/getdevice", {
        params
    })
}

export const updateDeviceRecord = () => {
    return axiosInstance.post("/excel/device/import-ignore")
}

export const updateVehicleRecord = () => {
    return axiosInstance.post("/excel/import-ignore")
}